package com.kong.api;

import com.kong.rabbitproducer.RabbitProducer;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
public class UserService {

    @Resource
    RabbitProducer producer;

    @GetMapping("getMsg")
    public String getMsg(String mas) {
        for (int i = 0; i <5 ; i++) {
            producer.stringSend(i+mas);
        }

        return mas;
    }
}
